package com.lcq.course.controller;

import com.lcq.course.entity.Good;
import com.lcq.course.service.GoodService;
import org.apache.ibatis.annotations.Param;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController

public class CourseListController {

    @Autowired
    GoodService goodService;

    @GetMapping("/good")
    public Good getGoodById(@Param("id") int id) {
        return goodService.getGoodById(id);
    }

}
